<?php

namespace App\Api\Logic\Validate;

class OrderValidate extends BaseValidate
{
    protected $rule = [
        'goods_id'=>'required',
        'goods_num'=>'required',
        'address_id'=>'required',
        'id'=>'required',
        'pageSize'=>'required',
        'page'=>'required',
        'pay_password'=>'required'
    ];
    protected $message = [
        'goods_id.required'=>'请选择下单的商品',
        'goods_num.required'=>'请选择商品的数量',
        'address_id.required'=>'请选择收货地址',
        'id.required'=>'请选择订单',
        'pageSize.required'=>'请输入每页显示条数',
        'page.required'=>'请输入如查看页数',
        'pay_password.required'=>'请输入支付密码'
    ];
    protected $scene = [
        'addOrder'=>'goods_id,goods_num,address_id',
        'payNotice'=>'id,pay_password',
        'getOrderInfo'=>'id',
        'getOrderList'=>'page,pageSize',
        'wechatPay'=>'id',
        'moreGoods'=>'goods_id',
        'updateOrderAddress'=>'id,address_id'
    ];
}
